-- GENERATED SPELL FOR [Summoned Daemon] --


function spell0_21726(pUnit, Event) --@Fire Shield,n/a--
pUnit:FullCastSpellOnTarget(37434,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_21726', 5000, 1)
end

function spell1_21726(pUnit, Event) --@Hellfire,n/a--
pUnit:FullCastSpellOnTarget(37428,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_21726', 0, 1)
end

function Sorts_21726(pUnit, Event)
local choix_sorts_21726 = math.random(0, 1)
if choix_sorts_21726 == 0 then
pUnit:RegisterEvent('spell0_21726', 1, 1)
end
if choix_sorts_21726 == 1 then
pUnit:RegisterEvent('spell1_21726', 1, 1)
end
end

function mob21726_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_21726', math.random(1500, 3000), 1)
end

function mob21726_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob21726_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob21726_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(21726, 1, 'mob21726_Action')
RegisterUnitEvent(21726, 2, 'mob21726_Leave')
RegisterUnitEvent(21726, 3, 'mob21726_Kill')
RegisterUnitEvent(21726, 4, 'mob21726_Die')
